#include "TcpServer.hpp"
#include <memory>

// ./server 8080
int main(int argc, char* argv[])
{
    if(argc != 2)
    {
        std::cout << "Usage: " << argv[0] <<" ServerPort[1024+]" << std::endl;
        return 1; 
    }
    uint16_t port = std::stoi(argv[1]);
    std::unique_ptr<TcpServer> tcp_srv(new TcpServer(port));

    tcp_srv->Init();
    tcp_srv->Run();

    return 0;
}